$t = ' 2011-01-31 17:21:22 ';
Print_r (Array (
Date (' Y year m month ', Strtotime ($t)),
Date (' Y year m month ', Strtotime (' + 1 month ', Strtotime ($t))),
Date (' Y year m month ', Strtotime (' + 2 month ', Strtotime ($t))),
));
Exit
Why is it
As I said at the beginning of the article-the reason for writing this article is because I can't find an ASP-like DateDiff function in PHP. After introducing how PHP handles the date and time, let's port the two commonly used functions in ASP to PHP.
Use the function date () to implement the displayed in the format: year-month-day hours: minutes: secRelated Time parameters:A-"AM" or "PM"A-"AM" or "PM"D-A few days, two digits, if less than two digits before the 0; such as: "01" to "31"D-Days of
PHP resolution for Strtotime ("-X Month") Bug
Strtotime ('-X month '); You may not get the expected results when it comes to month changes.
This is a bug in PHP:
https://bugs.php.net/bug.php?id=27793
?
For example: Current time: 2011-08-31 17:21:2
JavaScript Time Format Conversion Summary1. Current system locale format (tolocaledatestring and tolocaletimestring)Example: (new Date ()). toLocaleDateString () + "" + (new Date ()). toLocaleTimeString ()Results: January 29, 2008 16:13:112.
Title: Input two number, if the two number squared is greater than 100, the output of more than hundred digits, if the two number of squares less than 100, then output two number of the sum;Console.Write ("Please enter the first number a=");Double A
Post Source: http://yl-fighting.iteye.com/blog/1726285Reading Excel data with POI: (version number: POI3.7)1. Read ExcelJava code
Private list Rosolvefile (InputStream is, String suffix,
int StartRow) throws IOException, FileNotFoundException {
Official Address: http://docs.jquery.com/ui/datepicker,official example: http://jqueryui.com/demos/datepicker /.
A good address for DIY jQuery UI Interface Effects of site http://jqueryui.com/themeroller/
DatePicker basic usage:Copy codeThe Code is
Official address:
Http://docs.jquery.com/UI/Datepicker, official example:
http://jqueryui.com/demos/datepicker/。
A nice address for DIY JQuery UI interface effect site http://jqueryui.com/themeroller/
DatePicker Basic Use Method:
Copy Code
MySQL built-in function that uses str_to_date () to convert a string to a date inside MySQL.Example: The delimiter is the same, month and daySelect Str_to_date (' 2008-4-2 15:3:28 ', '%y-%m-%d%h:%i:%s ');Select Str_to_date (' 2008-08-09 08:9:30 ', '%
Consists of two files:
The first of the test.php
PHP "calendar.class.php"; $calendar=new calendar; $calendar-out ();
Second Calendar class: calendar.class.php
PhpclassCalendar {Private$year;//the current yearPrivate$month;//the
Official Address: http://docs.jquery.com/ui/datepicker,official example: http://jqueryui.com/demos/datepicker /.
A good address for DIY jQuery UI Interface Effects of site http://jqueryui.com/themeroller/
DatePicker basic usage:
Copy codeThe Code
JS method for selecting DOM elements /////////Note: Native JS selects DOM elements much faster than using jquery class libraries1. Select elements by ID /////////document.getElementById (' myID ');2. Select elements by Class
Overview
The date selection plugin is a flexible plug-in that you can define, including date format, language, limit selection date range, add related buttons, and other navigation.
At the same time, you can also use the keyboard to control it:
Page
Reference OldbodyFull Library Backup#!/bin/bash#mysqldump to fully backup MySQL dataif [-f/root/.bash_profile];thenSource/root/.bash_profileFiBakdir=/opt/mysqlbak/fullLogfile=/opt/mysqlbak/full/bak.logDate= ' Date +%y%m%d 'begin= ' date + '%y year%M
Reproduced!!!Ext.date is a singleton class that encapsulates a series of date manipulation functions, extending the functionality of JavaScript date, with some common features listed below.Ext.Date.add (date, interval, value) increases or decreases
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.